/*
 * Copyright 2013 NJUT  qixiaobo. All rights reserved.
 */
package com.fujitsu.nanjing.tieba.service;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.fujitsu.nanjing.tieba.base.BaseService;
import com.fujitsu.nanjing.tieba.ibator.CoreReportLog;
import com.fujitsu.nanjing.tieba.ibator.CoreReportLogCriteria;
import com.fujitsu.nanjing.tieba.model.ReportLog;

/**
 * ReportLogService.java
 * 
 * @author Administrator
 */
@Service
@Transactional
public class ReportLogService
		extends
			BaseService<CoreReportLog, CoreReportLogCriteria> {
	@Resource
	private ReportLog reportLog;
	@Override
	public CoreReportLog findById(String id) {
		return reportLog.selectByPrimaryKey(Integer.parseInt(id));
	}

	@Override
	public CoreReportLog insert(CoreReportLog t) {
		reportLog.insertSelective(t);
		return t;
	}

	@Override
	public void update(CoreReportLog t) {
		reportLog.updateByPrimaryKeySelective(t);

	}

	@Override
	public void delete(CoreReportLog t) {
		reportLog.deleteByPrimaryKey(t.getLogid());

	}
}
